package vip.george.bean.selector;

import org.springframework.context.annotation.ImportSelector;
import org.springframework.core.type.AnnotationMetadata;

public class MyImportSelector  implements ImportSelector {


    @Override
    public String[] selectImports(AnnotationMetadata annotationMetadata) {

        try {
//            Class<?> clazz = Class.forName("vip.george.bean.animal.Dog");
            Class<?> clazz = Class.forName("vip.george.bean.animal.Wolf");
            return new String[]{clazz.getName()};
        } catch (ClassNotFoundException e) {
            return new String[0];
        }

    }
}
